#! encoding: utf-8
from crm import CRM
from aaa import AAA


def delete_all():
    c = CRM()
    businessAccessAccounts = c.query_all_businessAccessAccounts()
    # print(c.businessAccessAccounts)

    a = AAA()
    for account in businessAccessAccounts:
        result = a.delete_account(account)
        print(result)

    c.delete_all()

def delete_aaa():
    s = '21fh'
    i = 800000
    a = AAA()
    for x in range(100):
        userid = s + str(i + x)
        account = userid + '@laotel.com'
        result = a.delete_account(account)
        print(result)


def delete_by_userid():
    pass

if __name__ == "__main__":
    delete_all()
    #delete_aaa()